<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>demo1</title>
</head>
<body>
<div id="app-3">
    <span v-if="seen">Now you see me</span>
    <button v-on:click="setVisible(false)">Hide</button>
    <button v-on:click="setVisible(true)">Show</button>
</div>
<script src="vue.js"></script>
<script>
    var app3 = new Vue({
        el: '#app-3',
        data: {
            seen: true
        },
        methods:{
            setVisible: function(visible){
                this.seen = visible;
            }
        }
    });
</script>
</body>
</html>